<!DOCTYPE html>
<html lang="en"
      xmlns:th="http://www.thymeleaf.org/">
<head th:replace="page/index::head">

</head>
<!--管理员操作替换的栏目框-->
<body class="layui-layout-body layuimini-all" >
<div class="layui-layout layui-layout-admin">

    <div class="layui-header header" th:fragment="nav">
        <div class="layui-logo layuimini-logo">
            <a href="">
                <img src="/images/logo.png" alt="logo">
                <h1>超市积分管理系统</h1>
            </a>
        </div>
        <a>
            <div class="layuimini-tool"><i title="展开" class="fa fa-outdent" data-side-fold="1"></i></div>
        </a>
        <ul class="layui-nav layui-layout-left layui-header-menu layui-header-pc-menu mobile layui-hide-xs">

            <li class="layui-nav-item layui-this" th:if="${session.user.role==1}" data-menu="currency">
                <a th:href="@{/notice/page}" href="javascript:;"><i class="fa fa-desktop"></i>发公告</a>
            </li>

        </ul>
        <ul class="layui-nav layui-layout-right">

            <li class="layui-nav-item" lay-unselect>
                <a href="javascript:;" data-refresh="刷新"><i class="fa fa-refresh"></i></a>
            </li>

            <li class="layui-nav-item " th:fragment="userinfo">
                <a href="#">
                    <!--用户头像-->
                    <img class="avatar" th:src="${session.user.avatar}" src=""
                         style="height: 60px;width: 60px;border-radius: 30px;" alt="avatar">
                </a>
                <dl class="layui-nav-child">
                    <dd>
                        <a href="javascript:;" class="uploadAvatar">上传头像</a>
                    </dd>
                    <dd>
                        <a th:href="@{/user/get_info/}" href="javascript:;" data-content-href=""
                           class="updateInfo" data-title="基本资料"
                           data-icon="fa fa-gears">修改资料</a>
                    </dd>
                    <dd>
                        <a th:href="@{/user/get_question/}" href="javascript:;" data-title="修改密码"
                           class="rePwd" data-icon="fa fa-gears">修改密码</a>
                    </dd>
                    <dd>
                        <a href="javascript:;" class="login-out">退出登录</a>
                    </dd>
                </dl>
            </li>
            <li class="layui-nav-item layuimini-select-bgcolor mobile layui-hide-xs">
                <a href="javascript:;" data-bgcolor="配色方案"><i class="fa fa-ellipsis-v"></i></a>
            </li>
        </ul>
    </div>

    <div class="layui-side layui-bg-black" th:fragment="left">
        <div  class="layui-side-scroll layui-left-menu">
            <!--左边菜单栏列表-->
            <ul class="layui-nav layui-nav-tree layui-left-nav-tree layui-this">
                <li class="layui-nav-item">
                    <a th:href="@{/manager/index/(id=${session.user.role})}"
                       href="javascript:void(0);" class="layui-menu-tips"
                       data-type="tabAdd" data-mpi="m-p-i-1"><i class="fa fa-home"></i>
                        <span class="layui-left-nav"> 主页</span></a>
                </li>
                <li class="layui-nav-item">
                    <a href="javascript:void(0);" class="layui-menu-tips"><i class="fa fa-clock-o"></i><span
                            class="layui-left-nav"> 历史记录</span> <span class="layui-nav-more"></span></a>
                    <dl class="layui-nav-child">
                        <dd>
                            <a th:href="@{/user/log_info/}" href="javascript:;" class="layui-menu-tips"
                               data-type="tabAdd" data-mpi="m-p-i-2">
                                <i class="fa fa-hourglass-end"></i>
                                <span class="layui-left-nav"> 登录日志</span>
                            </a>
                        </dd>
                    </dl>
                </li>
                <li class="layui-nav-item">
                    <a th:href="@{/admin/user_page/}" href="javascript:void(0);" class="layui-menu-tips"
                       data-type="tabAdd" data-mpi="m-p-i-1"
                       data-one-page="">
                        <i class="fa fa-users"></i>
                        <span
                                class="layui-left-nav">会员信息管理
                        </span>

                    </a>
                </li>
                <li class="layui-nav-item">
                    <a th:href="@{/product/list}" href="javascript:void(0);" class="layui-menu-tips" data-type="tabAdd"
                       data-mpi="m-p-i-1"
                       data-one-page="">
                        <i class="fa fa-shopping-cart"></i>
                        <span class="layui-left-nav">商品积分管理</span>

                    </a>
                </li>
                <li class="layui-nav-item">
                    <a th:href="@{/integration/list}" href="javascript:void(0);" class="layui-menu-tips"
                       data-type="tabAdd" data-mpi="m-p-i-1"
                       data-one-page="">
                        <i class="fa fa-trophy"></i>
                        <span class="layui-left-nav">会员积分管理</span>

                    </a>

                </li>
                <li class="layui-nav-item">
                    <a th:href="@{/notice/list}" href="javascript:void(0);" class="layui-menu-tips" data-type="tabAdd"
                       data-mpi="m-p-i-1"
                       data-one-page="">
                        <i class="fa fa-bullhorn"></i>
                        <span class="layui-left-nav">公告管理</span>

                    </a>

                </li>
            </ul>
        </div>
    </div>



</div>
<script type="text/javascript">

    layui.use(['element', 'layer', 'layuimini'], function () {


        $('.login-out').on("click", function () {
            layer.msg('正在退出登录', function () {
                window.location = '/user/logout';
            });
        });


        layuimini.listen();

    });



</script>
</body>